package com.qf.petmall.starter.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.qf.petmall.starter.entity.ShopCart;
import com.qf.petmall.starter.mapper.ShopCartMapper;
import com.qf.petmall.starter.service.IShopCartService;
import com.qf.petmall.starter.utils.R;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author author
 * @since 2022-12-08
 */
@Service
public class ShopCartServiceImpl extends ServiceImpl< ShopCartMapper, ShopCart > implements IShopCartService {

	@Override
	public R deleteCartsByid( List< Integer > cartIds ) {
		boolean b=removeBatchByIds( cartIds );
		if(b){
			return R.ok();
		}
		return R.error("删除失败！！");
	}
}
